<%-- 
    Document   : order_detail
    Created on : Mar 31, 2013, 11:57:29 PM
    Author     : duonghung1369
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib tagdir="/WEB-INF/tags/common_admin/" prefix="common" %>
<%@taglib uri="/struts-tags" prefix="s" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>

<!DOCTYPE HTML>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Administrator Page</title>
        <link rel="stylesheet" type="text/css" href="../resource/css/popup.css">
        <link rel="stylesheet" type="text/css" href="../resource/css/admin_style.css">
        <script type="text/javascript" src="../resource/js/adminfunctions.js"></script>
        <script type="text/javascript" src="../resource/js/ajaxfunctions.js"></script>
    </head>
    <body>
        <div class="admin-container">
            <common:header />
            <div class="leftColumn">
                <h2>Menu</h2>
                <div class="box sidemenu" style="height: 982px;">
                    <common:navigation />
                </div>
            </div>
            <div class="rightColumn">
                <div class="boxa round first grid">
                    <h2>Order Detail</h2>
                    <br/>
                    <table id="order-customer-information">
                        <tbody>
                            <tr>
                                <td class="left-column">Name</td>
                                <td class="right-column"><s:property value="order.user.profile.firstname" /> <s:property value="order.user.profile.lastname" /></td>
                            </tr>
                            <tr>
                                <td class="left-column">Email</td>
                                <td class="right-column"><s:property value="order.user.profile.email" /></td>
                            </tr>
                            <tr>
                                <td class="left-column">Phone</td>
                                <td class="right-column"><s:property value="order.user.profile.phoneNumber" /></td>
                            </tr>
                            <tr>
                                <td class="left-column">Address</td>
                                <td class="right-column"><s:property value="order.user.profile.address" /></td>
                            </tr>
                        </tbody>
                    </table>

                    <br/>
                    <br/>

                    <h2>Note</h2>
                    <br/>
                    <table id="order-note">
                        <tbody>
                            <tr>
                                <td class="left-column">Confirmation Number</td>
                                <td class="right-column"><s:property value="order.confirmationString" /></td>
                            </tr>
                            <tr>
                                <td class="left-column">Message</td>
                                <td class="right-column"><s:property value="order.note" /></td>
                            </tr>
                            <tr>
                                <td class="left-column">Date processed</td>
                                <td class="right-column"><s:property value="order.placedDatetime" /></td>
                            </tr>
                        </tbody>
                    </table>

                    <br/>
                    <br/>
                    <h2>Order items</h2>
                    <br/>
                    <table class="data display datatable" id="order-items" style="width: 90%">
                        <thead style="background-color: #f8f8f8">
                            <tr class="odd">
                                <td>Product</td>
                                <td style="text-align: center;">Quantity</td>
                                <td style="text-align: center;">Price</td>
                            </tr>
                        </thead>
                        <tbody>
                            <s:iterator value="order.orderItemses" id="orderItem" >
                                <tr>
                                    <td><s:property value="#orderItem.product.name" /></td>
                                    <td style="text-align: center;"><s:property value="#orderItem.quantity" /></td>
                                    <td style="text-align: center;"><s:property value="#orderItem.product.price" /></td>
                                </tr>
                            </s:iterator>
                            <tr style="background-color: antiquewhite; text-align: center;">
                                <td></td>
                                <td style="text-align: center; font-weight: bold; color: red;">Total</td>
                                <td style="font-weight: bold; color: red;"><s:property value="order.subAmount" /></td>
                            </tr>
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
        <div class="clear">
        </div>
        <common:footer />
    </body>
</html>
